<div class="modal-header">
    <h4 class="modal-title text-center">{{'advanced_search' | translate }} <button type="button" class="close" ng-click="cancel()">&times;</button></h4>
</div>
<style>
    #search-options .btn{
        background: white;
        border-radius: 2px;
        padding: 2px 15px;
        border: 1px solid #eee;
        margin-top:5px;
        outline: none;
    }
    #search-options .btn.active{
        border: 1px solid #797979;
        background: #797979;
        color: white;
        outline: none;
    }
    #search-options p.title,#search-options label.title{
        font-weight:bold;
        line-height:16px;
    }
    #search-options input{
        border-radius: 2px;
    }
</style>
<div class="modal-body" id="search-options" >
    <div class="form-group row">
        <label class="control-label col-xs-12 col-sm-5 col-md-4">{{'file_type_is' | translate }}:</label>
        <div class="col-xs-12 col-sm-7 col-md-8">
            <select class="form-control" name="type" ng-model="_type" ng-change="setTypeAndArg(_type, 'type')">
                <option value="all">{{ 'all' | translate }}</option>
                <option value="folder">{{ 'folder' | translate }}</option>
                <option value="document">{{ 'document' | translate }}</option>
                <option value="pdf">{{ 'pdf' | translate }}</option>
                <option value="zip">{{ 'zip' | translate }}</option>
                <option value="image">{{ 'image' | translate }}</option>
                <option value="excel">{{ 'excel' | translate }}</option>
                <option value="video">{{ 'video' | translate }}</option>
                <option value="text">{{ 'text' | translate }}</option>
                <option value="html">{{ 'html' | translate }}</option>
                <option value="ppt">{{ 'ppt' | translate }}</option>
                <option value="word">{{ 'word' | translate }}</option>
            </select>
        </div>
    </div>
    <div class="form-group row">
        <label class="control-label col-xs-12 col-sm-5 col-md-4">{{'file_name_contains' | translate }}: </label>
        <div class="col-xs-12 col-sm-7 col-md-8">
            <input class="form-control" type="text" ng-model="fileName" placeholder="{{ 'file_name_contains' | translate}}">
        </div>
    </div>
    <div class="form-group row" title="{{'last_modification_date' | translate }}">
        <label class="control-label col-xs-12 col-sm-5 col-md-4">{{'date_last_modified_is' | translate }}:</label>
        <div class="col-xs-12 col-sm-7 col-md-8">
            <select class="form-control" name="lastModifiedDate" ng-model="_lastModifiedDate" ng-change="setTypeAndArgBefore(_lastModifiedDate, 'lastModifiedDate')">
                <option value=""></option>
                <option value="today">{{ 'today' | translate }}</option>
                <option value="yesterday">{{ 'yesterday' | translate }}</option>
                <option value="within_last_week">{{ 'within_last_week' | translate }}</option>
                <option value="within_last_month">{{ 'within_last_month' | translate }}</option>
                <option value="within_90_days">{{ 'within_90_days' | translate }}</option>
                <option value="a_year_ago">{{ 'a_year_ago' | translate }}</option>
            </select>
        </div>
    </div>
    <div class="form-group row" title="{{'last_added_date' | translate }}">
        <label class="control-label col-xs-12 col-sm-5 col-md-4">{{'date_add_by' | translate }}:</label>
        <div class="col-xs-12 col-sm-7 col-md-8">
            <select class="form-control" name="lastAddedDate" ng-model="_lastAddedDate" ng-change="setTypeAndArgBefore(_lastAddedDate, 'lastAddedDate')">
                <option value=""></option>
                <option value="today">{{ 'today' | translate }}</option>
                <option value="yesterday">{{ 'yesterday' | translate }}</option>
                <option value="within_last_week">{{ 'within_last_week' | translate }}</option>
                <option value="within_last_month">{{ 'within_last_month' | translate }}</option>
                <option value="within_90_days">{{ 'within_90_days' | translate }}</option>
                <option value="a_year_ago">{{ 'a_year_ago' | translate }}</option>
            </select>
        </div>
    </div>
    <div class="form-group row hide" title="{{'last_viewed_date' | translate }}">
        <label class="control-label col-xs-12 col-sm-5 col-md-4">{{'date_last_viewed_is' | translate }}:</label>
        <div class="col-xs-12 col-sm-7 col-md-8">
            <select class="form-control" name="lastViewedDate" ng-model="_lastViewedDate" ng-change="setTypeAndArgBefore(_lastViewedDate, 'lastViewedDate')">
                <option value=""></option>
                <option value="today">{{ 'today' | translate }}</option>
                <option value="yesterday">{{ 'yesterday' | translate }}</option>
                <option value="within_last_week">{{ 'within_last_week' | translate }}</option>
                <option value="within_last_month">{{ 'within_last_month' | translate }}</option>
                <option value="within_90_days">{{ 'within_90_days' | translate }}</option>
            </select>
        </div>
    </div>
    <div class="form-group row hide" title="{{'file_add_by' | translate }}">
        <label class="control-label col-xs-12 col-sm-5 col-md-4">{{'file_add_by' | translate }}:</label>
        <div class="col-xs-12 col-sm-7 col-md-8">
            <select class="form-control" name="fileAddedBy" ng-model="_fileAddedBy" ng-change="setTypeAndArg(_fileAddedBy, 'fileAddedBy')">
                <option value=""></option>
                <option value="fxt_mb_win">{{ 'fxt_mb_win' | translate }}</option>
                <option value="cloud_reading_web">{{ 'cloud_reading_web' | translate }}</option>
                <option value="fxt_mb_ios">{{ 'fxt_mb_ios' | translate }}</option>
                <option value="fxt_mb_and">{{ 'fxt_mb_and' | translate }}</option>
                <option value="reader_mac">{{ 'reader_mac' | translate }}</option>
                <option value="reader_linux">{{ 'reader_linux' | translate }}</option>
            </select>
        </div>
    </div>
    <!--<form>-->
        <!--<div class="form-group">-->
            <!--<p class="title">{{'file_type_is' | translate }}: </p>-->
            <!--<button class="btn" ng-class="{'active':type=='pdf','':type!='pdf'}" ng-click="setTypeAndArg('pdf','type')">{{ 'pdf' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':type=='zip','':type!='zip'}" ng-click="setTypeAndArg('zip','type')">{{ 'zip' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':type=='image','':type!='image'}" ng-click="setTypeAndArg('image','type')">{{ 'image' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':type=='excel','':type!='excel'}" ng-click="setTypeAndArg('excel','type')">{{ 'excel' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':type=='video','':type!='video'}" ng-click="setTypeAndArg('video','type')">{{ 'video' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':type=='text','':type!='text'}" ng-click="setTypeAndArg('text','type')">{{ 'text' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':type=='html','':type!='html'}" ng-click="setTypeAndArg('html','type')">{{ 'html' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':type=='ppt','':type!='ppt'}" ng-click="setTypeAndArg('ppt','type')">{{ 'ppt' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':type=='word','':type!='word'}" ng-click="setTypeAndArg('word','type')">{{ 'word' | translate }}</button>-->
        <!--</div>-->
        <!--<div class="form-group" title="{{'file_name' | translate }}">-->
            <!--<label for="name-contains">{{'file_name_contains' | translate }}: </label>-->
            <!--<input class="form-control" id="name-contains" type="text" ng-model="fileName" placeholder="{{ 'file_name_contains' | translate}}">-->
        <!--</div>-->
        <!--&lt;!&ndash;<div class="form-group" title="file_name">&ndash;&gt;-->
            <!--&lt;!&ndash;<p class="title">{{'file_content_contains' | translate }}: </p>&ndash;&gt;-->
            <!--&lt;!&ndash;<input class="form-control" type="text">&ndash;&gt;-->
        <!--&lt;!&ndash;</div>&ndash;&gt;-->
        <!--<div class="form-group" title="{{'last_modification_date' | translate }}">-->
            <!--<p class="title">{{'date_last_modified_is' | translate }}: </p>-->
            <!--<button class="btn" ng-class="{'active':lastModifiedDate=='today','':type!='today'}" ng-click="setTypeAndArg('today','lastModifiedDate',0)">{{ 'today' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastModifiedDate=='yesterday','':type!='yesterday'}" ng-click="setTypeAndArg('yesterday','lastModifiedDate',1)">{{ 'yesterday' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastModifiedDate=='within_last_week','':type!='within_last_week'}" ng-click="setTypeAndArg('within_last_week','lastModifiedDate',7)">{{ 'within_last_week' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastModifiedDate=='within_last_month','':type!='within_last_month'}" ng-click="setTypeAndArg('within_last_month','lastModifiedDate',30)">{{ 'within_last_month' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastModifiedDate=='within_90_days','':lastModifiedDate!='within_90_days'}" ng-click="setTypeAndArg('within_90_days','lastModifiedDate',90)">{{ 'within_90_days' | translate }}</button>-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':lastModifiedDate=='2_6_month_ago','':type!='2_6_month_ago'}" ng-click="setTypeAndArg('2_6_month_ago','lastModifiedDate')">{{ '2_6_month_ago' | translate }}</button>&ndash;&gt;-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':lastModifiedDate=='7_12_months_ago','':type!='7_12_months_ago'}" ng-click="setTypeAndArg('7_12_months_ago','lastModifiedDate')">{{ '7_12_months_ago' | translate }}</button>&ndash;&gt;-->
            <!--<button class="btn" ng-class="{'active':lastModifiedDate=='a_year_ago','':type!='a_year_ago'}" ng-click="setTypeAndArg('a_year_ago','lastModifiedDate',365)">{{ 'a_year_ago' | translate }}</button>-->
        <!--</div>-->
        <!--<div class="form-group" title="{{'last_added_date' | translate }}">-->
            <!--<p class="title">{{'date_add_by' | translate }}: </p>-->
            <!--<button class="btn" ng-class="{'active':lastAddedDate=='today','':lastAddedDate!='today'}" ng-click="setTypeAndArg('today','lastAddedDate',0)">{{ 'today' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastAddedDate=='yesterday','':lastAddedDate!='yesterday'}" ng-click="setTypeAndArg('yesterday','lastAddedDate',1)">{{ 'yesterday' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastAddedDate=='within_last_week','':lastAddedDate!='within_last_week'}" ng-click="setTypeAndArg('within_last_week','lastAddedDate',7)">{{ 'within_last_week' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastAddedDate=='within_last_month','':lastAddedDate!='within_last_month'}" ng-click="setTypeAndArg('within_last_month','lastAddedDate',30)">{{ 'within_last_month' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastAddedDate=='within_90_days','':lastAddedDate!='within_90_days'}" ng-click="setTypeAndArg('within_90_days','lastAddedDate',90)">{{ 'within_90_days' | translate }}</button>-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':lastAddedDate=='2_6_month_ago','':lastAddedDate!='2_6_month_ago'}" ng-click="setTypeAndArg('2_6_month_ago','lastAddedDate')">{{ '2_6_month_ago' | translate }}</button>&ndash;&gt;-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':lastAddedDate=='7_12_months_ago','':lastAddedDate!='7_12_months_ago'}" ng-click="setTypeAndArg('7_12_months_ago','lastAddedDate')">{{ '7_12_months_ago' | translate }}</button>&ndash;&gt;-->
            <!--<button class="btn" ng-class="{'active':lastAddedDate=='a_year_ago','':lastAddedDate!='a_year_ago'}" ng-click="setTypeAndArg('a_year_ago','lastAddedDate',365)">{{ 'a_year_ago' | translate }}</button>-->
        <!--</div>-->
        <!--<div class="form-group hide" title="{{'last_viewed_date' | translate }}" style="">-->
            <!--<p class="title">{{'date_last_viewed_is' | translate }}: </p>-->
            <!--<button class="btn" ng-class="{'active':lastViewedDate=='today','':lastViewedDate!='today'}" ng-click="setTypeAndArg('today','lastViewedDate',0)">{{ 'today' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastViewedDate=='yesterday','':lastViewedDate!='yesterday'}" ng-click="setTypeAndArg('yesterday','lastViewedDate',1)">{{ 'yesterday' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastViewedDate=='within_last_week','':lastViewedDate!='within_last_week'}" ng-click="setTypeAndArg('within_last_week','lastViewedDate',7)">{{ 'within_last_week' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':lastViewedDate=='within_last_month','':lastViewedDate!='within_last_month'}" ng-click="setTypeAndArg('within_last_month','lastViewedDate',30)">{{ 'within_last_month' | translate }}</button>-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':lastViewedDate=='within_90_days','':lastViewedDate!='within_90_days'}" ng-click="setTypeAndArg('within_90_days','lastViewedDate',90)">{{ 'within_90_days' | translate }}</button>&ndash;&gt;-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':lastViewedDate=='2_6_month_ago','':lastViewedDate!='2_6_month_ago'}" ng-click="setTypeAndArg('2_6_month_ago','lastViewedDate')">{{ '2_6_month_ago' | translate }}</button>&ndash;&gt;-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':lastViewedDate=='7_12_months_ago','':lastViewedDate!='7_12_months_ago'}" ng-click="setTypeAndArg('7_12_months_ago','lastViewedDate')">{{ '7_12_months_ago' | translate }}</button>&ndash;&gt;-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':lastViewedDate=='a_year_ago','':lastViewedDate!='a_year_ago'}" ng-click="setTypeAndArg('a_year_ago','lastViewedDate',365)">{{ 'a_year_ago' | translate }}</button>&ndash;&gt;-->
        <!--</div>-->
        <!--<div class="form-group hide" title="{{'file_add_by' | translate }}" style="">-->
            <!--<p class="title">{{'file_add_by' | translate }}: </p>-->
            <!--&lt;!&ndash;   https://jira.foxitsoftware.cn/browse/CBASE-525 &ndash;&gt;-->
            <!--&lt;!&ndash;    1. Foxit MobilePDF for Windows  fxt_mb_win-->
                    <!--2. Cloud Reading Web            cloud_reading_web-->
                    <!--3. Foxit MobilePDF for iOS      fxt_mb_ios-->
                    <!--4. Foxit MobilePDF for Android  fxt_mb_and-->
                    <!--5. Foxit Reader for Mac         reader_mac-->
                    <!--6. Foxit Reader for Linux       reader_linux-->
            <!--&ndash;&gt;-->
            <!--<button class="btn" ng-class="{'active':fileAddedBy=='fxt_mb_win','':fileAddedBy!='fxt_mb_win'}" ng-click="setTypeAndArg('fxt_mb_win','fileAddedBy')">{{ 'fxt_mb_win' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':fileAddedBy=='cloud_reading_web','':fileAddedBy!='cloud_reading_web'}" ng-click="setTypeAndArg('cloud_reading_web','fileAddedBy')">{{ 'cloud_reading_web' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':fileAddedBy=='fxt_mb_ios','':fileAddedBy!='fxt_mb_ios'}" ng-click="setTypeAndArg('fxt_mb_ios','fileAddedBy')">{{ 'fxt_mb_ios' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':fileAddedBy=='fxt_mb_and','':fileAddedBy!='fxt_mb_and'}" ng-click="setTypeAndArg('fxt_mb_and','fileAddedBy')">{{ 'fxt_mb_and' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':fileAddedBy=='reader_mac','':fileAddedBy!='reader_mac'}" ng-click="setTypeAndArg('reader_mac','fileAddedBy')">{{ 'reader_mac' | translate }}</button>-->
            <!--<button class="btn" ng-class="{'active':fileAddedBy=='reader_linux','':fileAddedBy!='reader_linux'}" ng-click="setTypeAndArg('reader_linux','fileAddedBy')">{{ 'reader_linux' | translate }}</button>-->
            <!--&lt;!&ndash;<button class="btn" ng-class="{'active':fileAddedBy=='device_reader_web','':fileAddedBy!='device_reader_web'}" ng-click="setTypeAndArg('device_reader_web','fileAddedBy')">{{ 'device_reader_web' | translate }}</button>&ndash;&gt;-->
        <!--</div>-->
        <!--&lt;!&ndash;<div class="">&ndash;&gt;-->
            <!--&lt;!&ndash;<p class="title">{{'chosen_labels' | translate }}: </p>&ndash;&gt;-->
        <!--&lt;!&ndash;</div>&ndash;&gt;-->
    <!--</form>-->
</div>
<div class="modal-footer">
    <button class="btn btn-right-aside" type="button" ng-click="search()">{{'search_btn' | translate }}</button>
    <button class="btn btn-default" type="button" ng-click="reset()">{{'reset_options' | translate }}</button>
</div>
